#! /usr/bin/env python3

from ui.ui_bar import Ui_Dialog
from PySide2.QtWidgets import *
from model.clip_file import clipfile


class CViewBar(QDialog, Ui_Dialog):
    def __init__(self, parent=None):
        super(CViewBar, self).__init__(parent=parent)
        self.setupUi(self)
        self.init_ui()
        self.init_action()

    def init_ui(self):
        pass

    def init_action(self):
        self.pushButton.clicked.connect(self.close)
        clipfile.EventMessage.connect(self.label_message.setText)
        clipfile.EventBar.connect(self.progressBar.setValue)
